﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using KKCai.App.DAL.DaoImpl;

public partial class admin_news_list : KKCai.Web.ManagerPage
{
    public string PagerHtml = String.Empty;

    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void btnAdd_Click(object sender, EventArgs e)
    {
        Response.Redirect("add.aspx?cid=" + GetStringUrlParam("cid"));
    }
    protected void rpt_ItemCommand(object source, RepeaterCommandEventArgs e)
    {
        if (e.CommandName == "DoDelete")
        {
            int id = Convert.ToInt32(e.CommandArgument);

            new ArticleDao().Delete(id);

            if (new ArticleDao().Get(id) != null)
            {
                //Alert("删除失败!");
            }
            else
            {
                //Alert("删除成功!");
                //LoadList();
            }
        }
    }
}
